package com.ldgk.pim.client.view;


import com.google.gwt.maps.client.MapWidget;
import com.google.gwt.maps.client.geom.LatLng;
import com.google.gwt.search.client.LocalResult;
import com.ldgk.pim.data.Place;

/**
 * Represents a map view
 * @version 1.0
 */
public interface MapView extends View{
	
	/**
	 * Centers the map in a new defined point
	 * @param center - new map center
	 * @since 1.0
	 */
	public void setMapCenter(LatLng center);
	
	/**
	 * Retrieves the point the map is currently centered in
	 * @since 1.0
	 * @return - center point
	 */
	public LatLng getMapCenter();

	/**
	 * Adds a google search local result marker to the map
	 * @param result - local result
	 * @since 1.0
	 */
	public void addLocalResult(LocalResult result);
	
	/**
	 * Adds a database retrieved distribution place marker to the map
	 * @param place - distribution place
	 * @since 1.0
	 */
	public void addDistributionPlace(Place place);
	
	/**
	 * Clear all google local search results markers visible on the map
	 * @since 1.0
	 */
	public void clearLocalResults();

	/**
	 * Clear all distribution place markers visible on the map
	 * @since 1.0
	 */
	public void clearDistributionPlaces();
	
	/**
	 * Clear all markers on the map
	/**
	 * Clear all google local search results markers visible on the map
	 * @since 1.0
	 */
	public void clearAll();
	
	/**
	 * Retrieves the google map widget.
	 * @return - map widget
	 */
	public MapWidget getMapWidget();
}
